package com.emr.module.service.impl;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.emr.module.mapper.JieyueMapper;
import com.emr.module.domain.Jieyue;
import com.emr.module.service.IJieyueService;
import com.emr.common.support.Convert;

/**
 * 病历借阅 服务层实现
 * 
 * @author emr
 * @date 2019-02-26
 */
@Service
public class JieyueServiceImpl implements IJieyueService 
{
	@Autowired
	private JieyueMapper jieyueMapper;

	/**
     * 查询病历借阅信息
     * 
     * @param id 病历借阅ID
     * @return 病历借阅信息
     */
    @Override
	public Jieyue selectJieyueById(Integer id)
	{
	    return jieyueMapper.selectJieyueById(id);
	}
	
	/**
     * 查询病历借阅列表
     * 
     * @param jieyue 病历借阅信息
     * @return 病历借阅集合
     */
	@Override
	public List<Jieyue> selectJieyueList(Jieyue jieyue)
	{
	    return jieyueMapper.selectJieyueList(jieyue);
	}
	
    /**
     * 新增病历借阅
     * 
     * @param jieyue 病历借阅信息
     * @return 结果
     */
	@Override
	public int insertJieyue(Jieyue jieyue)
	{
	    return jieyueMapper.insertJieyue(jieyue);
	}
	
	/**
     * 修改病历借阅
     * 
     * @param jieyue 病历借阅信息
     * @return 结果
     */
	@Override
	public int updateJieyue(Jieyue jieyue)
	{
	    return jieyueMapper.updateJieyue(jieyue);
	}

	/**
     * 删除病历借阅对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
	@Override
	public int deleteJieyueByIds(String ids)
	{
		return jieyueMapper.deleteJieyueByIds(Convert.toStrArray(ids));
	}

	@Override
	public List<Map<String, Object>> selectjieyuerenId(Integer jieyuerenId) {
		// TODO Auto-generated method stub
		return jieyueMapper.selectjieyuerenId(jieyuerenId);
	}
	
}
